/*
 * libkysdk-system's Library
 *
 * Copyright (C) 2023, KylinSoft Co., Ltd.
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 3 of the License, or (at your option) any later version.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this library.  If not, see <https://www.gnu.org/licenses/>.
 *
 * Authors: Yunhe Liu <liuyunhe@kylinos.cn>
 *
 */

#ifndef LIBKYREALTIMEINFO_H
#define LIBKYREALTIMEINFO_H

#if __cplusplus
extern "C"
{
#endif
/**
 * @brief 获取瞬时网速信息
 * 
 * @param nc 网卡名称，如eno1
 * @return float 瞬时网速
 */
extern float kdk_real_get_net_speed(const char *nc);

/**
 * @brief 获取CPU温度
 * 
 * 
 * @return double CPU温度
 */
extern double kdk_real_get_cpu_temperature();

/**
 * @brief 获取磁盘温度
 * 
 * @param name 磁盘名称，应当是例如/dev/sda这种绝对路径
 * @return int 磁盘温度
 */
extern int kdk_real_get_disk_temperature(const char *name);

/**
 * @brief 获取磁盘转速
 * 
 * @param name 磁盘名称，应当是例如/dev/sda这种绝对路径
 * @return int 磁盘转速
 */
extern int kdk_real_get_disk_rate(const char *name);

/**
 * @brief 获取下载的瞬时网速信息
 * 
 * @param nc 网卡名称，如eno1
 * @return float 下载的瞬时网速
 */
extern float kdk_real_get_if_speed(const char *nc);

#if __cplusplus
}
#endif

#endif // LIBKYREALTIMEINFO_H
